package com.ityu.cloudclientone.sentinel;

import com.alibaba.csp.sentinel.adapter.spring.webmvc.callback.UrlCleaner;
import org.springframework.stereotype.Component;

/**
 * author: yu.jl
 * e-mail: bbfx89625@gmail.com
 * time  : 2021/6/25
 * desc  :
 */
@Component
public class CustomUrlCleaner implements UrlCleaner {
    @Override
    public String clean(String originUrl) {
        System.out.println(originUrl);
        //TODO 对一类的url进行统一返回一个资源名称，这样在添加限流规则的时候，就不需要每一个url进行规则设定。
        System.out.println("CustomUrlCleaner-originUrl");
        return originUrl;
    }
}
